<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="UTF-8" />
		<meta http-equiv="X-UA-Compatible" content="IE=edge" />
		<meta name="viewport" content="width=device-width, initial-scale=1.0" />
		<title>Document</title>
	</head>
	<style>
		/* 基本配置 */
		* {
			padding: 0px;
			margin: 0px;
		}
		body {
			background-image: url(./bg.webp);
			background-repeat: no-repeat;
			background-size: cover;
		}
		.container {
			width: 100%;
			height: 500px;
			border: 1px solid black;
			display: flex;
			align-items: center;
			align-content: center;
			justify-content: space-around;
			margin-top: 250px;
		}
		/* 动画 */
		.container .one {
			width: 180px;
			height: 180px;
			background-image: url(./west_01.png);
			/* 雪碧图8片，所以八步 */
			animation: west1 1.4s steps(8) infinite;
			background-position: 0px 0px;
		}

		@keyframes west1 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1600px 0;
			}
		}

		/* 表示适用于webkit内核的浏览器 */
		@-webkit-keyframes west1 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1600px 0;
			}
		}

		.container .two {
			width: 180px;
			height: 180px;
			background-image: url(./west_02.png);
			animation: west2 1.4s steps(8) infinite;
			background-position: 0px 0px;
		}
		@keyframes west2 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1600px 0;
			}
		}
		@-webkit-keyframes west2 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1600px 0;
			}
		}

		.container .three {
			width: 180px;
			height: 180px;
			background-image: url(./west_03.png);
			animation: west3 1.4s steps(8) infinite;
			background-position: 0px 0px;
		}
		@keyframes west3 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1360px 0;
			}
		}
		@-webkit-keyframes west3 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1360px 0;
			}
		}

		.container .four {
			width: 180px;
			height: 180px;
			background-image: url(./west_04.png);
			animation: west4 1.4s steps(8) infinite;
			background-position: 0px 0px;
		}
		@keyframes west4 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1680px 0;
			}
		}
		@-webkit-keyframes west4 {
			0% {
				background-position: 0 0;
			}
			100% {
				background-position: -1680px 0;
			}
		}
	</style>
	<body>
		<div class="container">
			<div class="one"></div>
			<div class="two"></div>
			<div class="three"></div>
			<div class="four"></div>
		</div>
	</body>
</html>
